package com.zyw.mvc.sitemesh;

import org.sitemesh.builder.SiteMeshFilterBuilder;
import org.sitemesh.config.ConfigurableSiteMeshFilter;

/**
 * @author zhangyw
 * @date 2018/2/1 16:33
 */
public class SiteMeshConfigurableFilter extends ConfigurableSiteMeshFilter {

    @Override
    protected void applyCustomConfiguration(SiteMeshFilterBuilder builder) {
        builder.addDecoratorPath("/*", "/decorator/default.html")
                .addExcludedPath("/login.html*")
                .addExcludedPath("/webjars/*");

        builder.setMimeTypes("text/html", "application/xhtml+xml", "application/vnd.wap.xhtml+xml");
    }
}
